package com.atguigu.order.orders.feign;


import com.atguigu.common.utils.R;
import com.atguigu.order.vo.OrderItemVo;
import com.atguigu.order.vo.OrderToWareTo;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

import java.util.List;


@FeignClient("gulimall-ware")
public interface WareFeign {
    //远程调用获取购物车中选中的数据
    @PostMapping("ware/waresku/skuId/info")
    R skuIdInfo(@RequestBody List<Long> skuIds);

    /**
     * 商品远程调用根据商品id锁定对应的商品
     */
    @PostMapping("ware/waresku/order/lock")
    R orderLock(@RequestBody List<OrderToWareTo> orderToWareTos);
}
